package com.xja.cloud.controller;

import com.xja.cloud.entity.ResultVO;
import com.xja.cloud.service.AdminService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/admin")
public class AdminController {
    @Autowired
    private AdminService adminService;
    Logger logger = LoggerFactory.getLogger(AdminController.class);

    @RequestMapping("/list")
    public ResultVO list(){
        logger.info("查询管理员");
        return ResultVO.success("查询成功",adminService.selectList());
    }
}
